
app.controller('btnCtrl', ['$scope', '$http', BtnController]);
function BtnController($scope, $http){

    $scope.bindBtn = function(event) {
        switch(event){
            case 'event-to-add':
            {
                window.top.add_tab('员工工资申请单 - 新增', '/web/base/tbUserPayApply/toAdd', 1);
                break;
            }
            case 'LAYTABLE_EXPORT_DATA':
            {
                $scope.doExport('/api/inter/tbUserPayApply/export');
                break;
            }

        };
    }
}


//表格双击
app.controller('dbClickCtrl', ['$scope', '$http', DbClickController]);
function DbClickController($scope, $http){
    $scope.doubleClick = function(data) {
        window.top.add_tab('员工工资申请单 - 编辑','/web/base/tbUserPayApply/toEdit?bid=' + data.bid);
    }
}

